package vn.vfriends.id.service.impl;

import java.util.List;
import javax.inject.Inject;
import vn.vfriends.id.jpa.controller.PageJpaController;
import vn.vfriends.id.jpa.entity.Page;
import vn.vfriends.id.service.PageService;

/**
 *
 * @author tuan@vfriends.vn
 */
public class PageServiceImpl implements PageService {

    @Inject private PageJpaController pageController;
    
    @Override
    public void create(Page page) throws Exception {
        pageController.create(page);
    }

    @Override
    public void edit(Page page) throws Exception {
        pageController.edit(page);
    }

    @Override
    public void destroy(Long id) throws Exception {
        pageController.destroy(id);
    }

    @Override
    public List<Page> find() {
        return pageController.find();
    }

    @Override
    public Page find(Long id) {
        return pageController.find(id);
    }

    @Override
    public Page findByName(String name) {
        return pageController.findByName(name);
    }

    @Override
    public Page findByLink(String link) {
        return pageController.findByLink(link);
    }

    @Override
    public int getCount() {
        return pageController.getCount();
    }

}
